#ifndef OPCODE_H
#define OPCODE_H

enum OpCode {
    F_POP_VALUE,
    F_EFUNV,
    F_NUMBER,
    F_STRING,
    F_CONST0,
    F_CALL_FUNCTION_BY_ADDRESS,
    F_RETURN,
    F_RETURN_ZERO,
    F_LOCAL,
    F_LOCAL_LVALUE, /* must follow F_LOCAL */
    F_GLOBAL,
    F_GLOBAL_LVALUE, /* must follow F_GLOBAL */
    F_ASSIGN,
    F_VOID_ASSIGN,
    F_VOID_ASSIGN_LOCAL,
    F_ADD,
    OPCODE_EFUN_BEGIN,
};

enum OpCodeEFun {
    F_PRINTF = OPCODE_EFUN_BEGIN,
    OPCODE_NUM, /* number of opcodes */
};

extern char *g_opcode_repr[OPCODE_NUM];

#endif
